package cn.edu.seig.textbook.service;

import cn.edu.seig.textbook.domain.dto.TotalOrders;
import cn.edu.seig.textbook.domain.pojo.Orders;
import cn.edu.seig.textbook.enums.OrderEnum;
import com.baomidou.mybatisplus.extension.service.IService;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author day
 * @since 2024-11-07
 */
public interface IOrdersService extends IService<Orders> {
    List<TotalOrders> getTotalOrders();
    List<Orders> getOrdersByStudentId(@Param("studentId") int studentId);
    List<Orders> getOrdersByStatus(@Param("orderStatus") OrderEnum orderStatus);
    List<Orders> getOrdersByStudentName(@Param("studentName") String studentName);
    List<Orders> getOrdersByTextbookName(@Param("textbookName") String textbookName);
    int addOrder(Orders order);
    int updateOrder(Orders order);
    int deleteOrder(@Param("orderId") int orderId);
    int setOrderStatus(OrderEnum orderStatus);
}
